Currently, infrared remote control is the most widely used means of communication and remote control, which can be applied to electrical appliances such as television, air conditioner, electric fans, set-top boxes, DVD, and so on. At present, the control of one entity infrared remote controller purchased from the market on electrical appliances is immutable, i.e. one entity infrared remote controller may only control one or several corresponding electric appliances. Due to its limited control range, the entity infrared remote controller cannot support users to control other new developed electric appliances, thus a learning function is developed, i.e., a terminal may acquire the functions of an infrared remote controller which is to be learned by learning different function keys of the infrared remote controller. Thereby the terminal may control the electric appliances that the infrared remote controller controls.
At present, mechanical remote controllers and mobile terminals with infrared functions, such as mobile phones and tablet computers, may learn various functions of keys of infrared remote controllers, making it unnecessary for users to change remote controllers frequently, and remotely controlling various electrical appliances via one terminal, which expands the control of the terminals, and makes it more convenient for users. However, when learning the functions of a key of an infrared remote controller, a mobile terminal samples the transmitted code information of a learned key for only once, but one key of some remote controllers may transmit different code values according to different frequencies of operation performed on the key. In this case, the mobile terminal may not truly and comprehensively learn all the code values of the key, which may cause failure of the mobile terminal in realizing all the functions of the key when remotely controlling electric appliances.